/*
 * Created by Christopher King
 * Copyright (C) 2007 Christopher King, All Rights Reserved.
 */

package us.cirion.adventure.engine.result;

import us.cirion.adventure.engine.GameDisplay;
import us.cirion.adventure.engine.Result;

/**
 * Displays a textual message to the user.
 * 
 * @author Chris
 */
public class DisplayMessage implements Result
{

	private GameDisplay display;
	private String message;

	/**
	 * Constructs the message that should be displayed.
	 * 
	 * @param display The user interface that should be used to show the
	 *            message.
	 * @param message The message to show.
	 */
	public DisplayMessage(GameDisplay display, String message)
	{
		this.display = display;
		this.message = message;
	}

	/**
	 * Displays the message to the user.
	 */
	public void execute()
	{
		display.displayMessage(message);
	}

}
